package cc.linker.steplink.crm.merchanth5.dao;


import cc.linker.steplink.crm.merchanth5.pojo.VipCustomerLogPo;
import cc.linker.steplink.crm.merchanth5.pojo.VipPo;
import cc.linker.steplink.crm.merchanth5.pojo.acs.ProtectPo;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Component;

import java.util.List;
import java.util.Map;

/**
 * @author huhj
 */
@Component
public interface VipCustomerLogDao {


    List<VipCustomerLogPo> getVipLogList(Map<String, Object> param);

    void refundVip(Map<String, String> param);

    List<VipPo> getViplist(Map<String, Object> param);

    VipPo vipInfo(Map<String, Object> param);

    VipPo vipBaseInfo(Map<String, Object> param);

    VipCustomerLogPo vipLogInfo(@Param("id") Long id);

    VipCustomerLogPo vipLogInfoByOrderSn(@Param("orderSn") String orderSn);

    void addLog(VipCustomerLogPo vipLog);

    List<ProtectPo> getRefundData(@Param("orderSn") String orderSn);

    ProtectPo getProtectInfo(@Param("orderSn") String orderSn);
    void doneOrder(Map<String, Object> orderParam);

    void addRefund(Map<String, Object> param);

    List<Long> getVipIdsByGoodsId(@Param("goodsId") String goodsId);

    List<ProtectPo> getProtectPoListData(String orderSn);

    VipPo vipInfoByOpen(Map<String, Object> param);

    String getGlobalopenIdByCustomerId(@Param("customerId") String customerId);

    String getProtectStatus(@Param("orderSn") String orderSn);

    Integer getIsVip(@Param("customerId") String customerId);

    Integer getIsVipByApp(@Param("customerId") String customerId);

    List<String> getappUserIdByCustomerId(@Param("customerId") String customerId);

    String getAppUserIdByCustomerId(@Param("customerId") String customerId);

    List<Map<String, Object>> getVipRightList(@Param("id") Long id);

    List<Map<String, Object>> getLevelRightList(Map<String, Object> map);

    List<Map<String, Object>> levelRight(String levelId);

    Map<String, Object> getCustomerById(String customerId);

    void addGrowth(Map<String, Object> log);

    void addIntegral(Map<String, Object> log);

    int getGiftsCount(@Param("levelId") String levelId,@Param("customerId") String customerId);

    void insertGifts(@Param("levelId") String levelId,@Param("customerId") String customerId,@Param("orgId") String orgId);

    Integer getIsVipLevel(@Param("customerGrowthScore") int customerGrowthScore,@Param("orgId") String orgId);

    int getVipOpenCount(Long id);

    List<Map<String, Object>> getUnpayList();

    void delVipLog(String logId);

    Map<String, Object> getIntegralVipInfo(Map<String, Object> param);

    Map<String, Object> getVipInfo(@Param("vipId") long vipId,@Param("customerId") String customerId);

    void addSaleNum(Long integralVipId);

    Integer getCustomerLevel(String customerId);

    void saveIntegralGoods(Map<String, Object> tmp);

    List<Map<String, Object>> getUnpayOrderList();

    List<Map<String, Object>> getVipCoupons(String id);

    int getIsCoupon(Long vipId);

    int getIsCouponLevel(String vipId);

    Integer ratio(@Param("vipId") Long vipId);

    Integer getPromoterCount(@Param("shareCustomerId") String shareCustomerId);

    Map<String, Object> getLastVipLog(@Param("vipId") Long vipId,@Param("customerId") String customerId);

    VipCustomerLogPo getLogInfo(long logId);

    VipCustomerLogPo getLastUnrefundVipLog(VipCustomerLogPo vipCustomerLog);

    void saveLog(VipCustomerLogPo lastUnrefundVipLog);

    void refundAllVip(VipCustomerLogPo vcpPo);

    List<Map> getQuotaVipList(@Param("quotaVips") String quotaVips,@Param("customerId") String customerId);

    List<Map<String, Object>> getVipCoupon(String customerId);

    Map<String, Object> getVipBaseInfo(String id);

    void setIsRead(String customerId);
}
